package cn.tedu.boot31.conetoller;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class Bmi2Controller {
    @RequestMapping("/bmi2")
    public String bmi2(float h,float w){
        float bmi=w/(h*h);
        String info=null;
        if (bmi<18.5){
            info="瘦了";
        }else if (bmi<24){
            info="正常";
        }else {
            info="胖";
        }
        return info;
    }
}
